package dreamtwodancetiktokenumsmyredis

type DrawPrizeEnums struct {
}

var DrawPrizeEnumsObject DrawPrizeEnums

const (
	DrawPrizeBatchNumber   = "DrawPrizeBatchNumber"   //用户抽奖批次，默认保底+1
	DrawPrizeCurrentNumber = "DrawPrizeCurrentNumber" //用户当前累计抽奖次数，满足条件后重置，批次+1

	// 碎片可赠送次数获取类型
	PieceGiveNumGetTypeBasicCfg     = 0 // 使用保底配置
	PieceGiveNumGetTypeDrawPrize    = 1 // 抽满次数获取
	PieceGiveNumGetTypeGiveOther    = 2 // 赠送碎片减少
	PieceGiveNumGetTypeAdminOperate = 3 // 后台补发

	// 碎片可赠送次数加减 枚举
	PieceGiveNumChangeLogTypeAdd     = 1 //增加
	PieceGiveNumChangeLogTypeReduced = 2 //减少

	// 服饰获取加减 枚举
	ClothesChangeLogTypeAdd     = 1 //增加
	ClothesChangeLogTypeReduced = 2 //减少

	// 挖矿奖励发放枚举
	MiningSendRewardsScript          = 1 //脚本
	MiningSendRewardsExitProactively = 2 // 离开城池

	// 服饰获取来源
	DanceComposeClothesChangeLogSourceDirectDrawPrize     = 1 // 抽奖直接获得
	DanceComposeClothesChangeLogSourceAdminAdd            = 2 // 后台补发
	DanceComposeClothesChangeLogSourceHourRank            = 3 // 小时榜发放
	DanceComposeClothesChangeLogSourceDayRank             = 4 // 日榜发放
	DanceComposeClothesChangeLogSourceSingleWeekRank      = 5 // 个人周榜发放
	DanceComposeClothesChangeLogSourceCoupleWeekRank      = 6 // CP周榜发放
	DanceComposeClothesChangeLogSourceGiftPackageActivity = 7 // 礼包活动
	DanceComposeClothesChangeLogSourcePrizeDrawCPGift     = 8 // 抽奖CP赠送
	DanceComposeClothesChangeLogSourceGiftPackCPGift      = 9 // 礼包CP赠送

	// 抽奖信息队列枚举
	DanceActivitiesDrawPrizeListLogSourceRoomGiftPush         = 1 // 直播间刷礼物推送
	DanceActivitiesDrawPrizeListLogSourceDistributeNumberPush = 2 // 补发抽奖次数推送
	DanceActivitiesDrawPrizeListLogSourceRoomPull             = 3 // 直播间拉取
)

func (e DrawPrizeEnums) PieceGiveNumSourceNameMap() map[int]string {
	m := make(map[int]string)
	for _, s := range e.PieceGiveNumSource() {
		m[s] = e.PieceGiveNumString(s)
	}
	return m
}

func (e DrawPrizeEnums) PieceGiveNumSource() []int {
	return []int{
		PieceGiveNumGetTypeBasicCfg,
		PieceGiveNumGetTypeDrawPrize,
		PieceGiveNumGetTypeGiveOther,
		PieceGiveNumGetTypeAdminOperate,
	}
}

func (e DrawPrizeEnums) ClothesChangeLogSourceNameMap() map[int]string {
	m := make(map[int]string)
	for _, s := range e.ClothesChangeLogSource() {
		m[s] = e.ClothesChangeLogString(s)
	}
	return m
}

func (e DrawPrizeEnums) ClothesChangeLogSource() []int {
	return []int{
		DanceComposeClothesChangeLogSourceDirectDrawPrize,
		DanceComposeClothesChangeLogSourceAdminAdd,
		DanceComposeClothesChangeLogSourceHourRank,
		DanceComposeClothesChangeLogSourceDayRank,
		DanceComposeClothesChangeLogSourceSingleWeekRank,
		DanceComposeClothesChangeLogSourceCoupleWeekRank,
		DanceComposeClothesChangeLogSourceGiftPackageActivity,
		DanceComposeClothesChangeLogSourcePrizeDrawCPGift,
		DanceComposeClothesChangeLogSourceGiftPackCPGift,
	}
}

// 碎片可赠送次数枚举
func (e DrawPrizeEnums) PieceGiveNumString(tag int) string {
	switch tag {
	case PieceGiveNumGetTypeBasicCfg:
		return "使用保底配置"
	case PieceGiveNumGetTypeDrawPrize:
		return "抽满次数获取"
	case PieceGiveNumGetTypeGiveOther:
		return "赠送碎片减少"
	case PieceGiveNumGetTypeAdminOperate:
		return "后台补发"
	default:
		return "未知"
	}
}

// 一级服饰枚举
func (e DrawPrizeEnums) ClothesChangeLogString(tag int) string {
	switch tag {
	case DanceComposeClothesChangeLogSourceDirectDrawPrize:
		return "抽奖直接获得"
	case DanceComposeClothesChangeLogSourceAdminAdd:
		return "后台补发"
	case DanceComposeClothesChangeLogSourceHourRank:
		return "小时榜发放"
	case DanceComposeClothesChangeLogSourceDayRank:
		return "日榜发放"
	case DanceComposeClothesChangeLogSourceSingleWeekRank:
		return "个人周榜发放"
	case DanceComposeClothesChangeLogSourceCoupleWeekRank:
		return "CP周榜发放"
	case DanceComposeClothesChangeLogSourceGiftPackageActivity:
		return "礼包活动"
	case DanceComposeClothesChangeLogSourcePrizeDrawCPGift:
		return "抽奖CP赠送"
	case DanceComposeClothesChangeLogSourceGiftPackCPGift:
		return "礼包CP赠送"
	default:
		return "未知"
	}
}

// 挖矿奖励发放枚举
func (e DrawPrizeEnums) MiningSendRewardsLogSourceNameMap() map[int]string {
	m := make(map[int]string)
	for _, s := range e.MiningSendRewardsLogSource() {
		m[s] = e.MiningSendRewardsLogString(s)
	}
	return m
}

func (e DrawPrizeEnums) MiningSendRewardsLogSource() []int {
	return []int{
		MiningSendRewardsScript,
		MiningSendRewardsExitProactively,
	}
}

func (e DrawPrizeEnums) MiningSendRewardsLogString(tag int) string {
	switch tag {
	case MiningSendRewardsScript:
		return "脚本"
	case MiningSendRewardsExitProactively:
		return "离开城池"
	default:
		return "未知"
	}
}

// 抽奖信息队列枚举
func (e DrawPrizeEnums) DrawPrizeListLogSourceNameMap() map[int]string {
	m := make(map[int]string)
	for _, s := range e.DrawPrizeListLogSource() {
		m[s] = e.DrawPrizeListLogString(s)
	}
	return m
}

func (e DrawPrizeEnums) DrawPrizeListLogSource() []int {
	return []int{
		DanceActivitiesDrawPrizeListLogSourceRoomGiftPush,
		DanceActivitiesDrawPrizeListLogSourceDistributeNumberPush,
		DanceActivitiesDrawPrizeListLogSourceRoomPull,
	}
}

func (e DrawPrizeEnums) DrawPrizeListLogString(tag int) string {
	switch tag {
	case DanceActivitiesDrawPrizeListLogSourceRoomGiftPush:
		return "直播间刷礼物推送"
	case DanceActivitiesDrawPrizeListLogSourceDistributeNumberPush:
		return "补发抽奖次数推送"
	case DanceActivitiesDrawPrizeListLogSourceRoomPull:
		return "直播间拉取"
	default:
		return "未知"
	}
}
